<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>快来申请吧</title>
		<meta name = "viewport" content = "width = device-width, initial-scale = 1.0,
			 maximum-scale = 1.0, user-scalable = 0" />
		<link rel="stylesheet" href="../css/main.css" />
		<link rel="stylesheet" href="../css/style.css" />
		<link rel="stylesheet" href="../css/mobileSelect.css" />
	</head>
	<body>
		<div id="apply">
			<div v-show="showMain">
				<p class="warnInfo">温馨提示：填写真实有效信息，有助于您更快解决资金难题</p>
				<div class="stepThree">
					<span>
						<strong class="checkActive1">1</strong>
						<dd class="checkActive2">贷款信息</dd>
					</span>
					<span>
						<strong :class="{checkActive1:isTwo}">2</strong>
						<dd :class="{checkActive2:isTwo}">信用资产</dd>
					</span>
					<span>
						<strong :class="{checkActive1:stepSan}">3</strong>
						<dd :class="{checkActive2:stepSan}">我要认证</dd>
					</span>
				</div>
				<!--基本信息-->
				<div id="basic" v-show="stepOne">
					<p class="titleStep">基本信息</p>
					<mt-field class="borderBottom" label="姓名" placeholder="请输入真实姓名" type="text" 
						v-model.lazy="loanName" :attr="{maxlength:20}" :disabled="false"></mt-field>
					<mt-field class="borderBottom" label="身份证号码" placeholder="请输入身份证号码" type="text" 
						v-model.lazy="idCard" :attr="{maxlength:18}" :disabled="false"></mt-field>
					<mt-field class="borderBottom" label="期望金额" placeholder="请输入1-50万金额" type="text" 
						v-model.lazy="loadMoney" :attr="{maxlength:5}">&nbsp;万元</mt-field>
						
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">贷款期限</span>
						</div>
						<div class="mint-cell-value">
							<span id="loanMonths">请选择贷款期限&nbsp;</span>
							<strong class="mint-field-other"> > </strong>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">贷款用途</span>
						</div>
						<div class="mint-cell-value">
							<span id="purpose">请选择贷款用途&nbsp;</span>
							<strong class="mint-field-other"> > </strong>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">贷款城市</span>
						</div>
						<div class="mint-cell-value">
							<span id="city" ref="citys">请选择贷款城市</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">婚姻</span>
						</div>
						<div class="mint-cell-value">
							<span id="marriage">请选择婚姻</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">学历</span>
						</div>
						<div class="mint-cell-value">
							<span id="education">请选择学历</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">居住城市</span>
						</div>
						<div class="mint-cell-value">
							<span id="liveCity" ref="liveCitys">请选择居住城市</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					
					<button @click="nextTick1" class="buttonOne">下一步</button>
					
				</div>
				
				<!--信用资产信息-->
				<div id="means" v-show="stepTwo">
					<p class="titleStep">职业、信用、资产信息</p>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">职业身份</span>
						</div>
						<div class="mint-cell-value">
							<span id="professionTypes">请选择职业身份</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<!--上班族或自由职业者-->
					<div v-show="isZhiye">
						<mt-field class="borderBottom" label="现单位名称" placeholder="请输入单位名称" type="text" 
							v-model.lazy="unitName"></mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">现单位性质</span>
							</div>
							<div class="mint-cell-value">
								<span id="unitNature">请选择单位性质</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="现单位职务" placeholder="请输入单位职务" type="text" 
							v-model.lazy="duty"></mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">现单位工作时间</span>
							</div>
							<div class="mint-cell-value">
								<span id="workYears">请选择单位工作时间</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="月总收入" placeholder="请输入月总收入" type="text" 
							v-model.lazy="income">元</mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">发薪方式</span>
							</div>
							<div class="mint-cell-value">
								<span id="paymentMethod">请选择发薪方式</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">是否缴纳社保/公积金</span>
							</div>
							<div class="mint-cell-value">
								<span id="socialFund">请选择是否缴纳</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div v-show="isShebao">
							<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
								<div class="mint-cell-title">
									<span class="mint-cell-text">本地社保连续缴纳时间</span>
								</div>
								<div class="mint-cell-value">
									<span id="socialMonth">请选择缴纳时间</span>
									<strong class="mint-field-other">&nbsp; > </strong>
								</div>
							</div>
							<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
								<div class="mint-cell-title">
									<span class="mint-cell-text">本地公积金连续缴纳时间</span>
								</div>
								<div class="mint-cell-value">
									<span id="fundMonth">请选择缴纳时间</span>
									<strong class="mint-field-other">&nbsp; > </strong>
								</div>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">现单位地址</span>
							</div>
							<div class="mint-cell-value">
								<span id="unitAddress" ref="unitAddresses">请选择现单位地址</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
					</div>
					<!--法人-->
					<div v-show="isFaren">
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">企业类型</span>
							</div>
							<div class="mint-cell-value">
								<span id="unitType">请选择企业类型</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="企业名称" placeholder="请输入企业名称" type="text" 
							v-model.lazy="unitName"></mt-field>
						<mt-field class="borderBottom" label="月经营流水" placeholder="请输入月经营流水" type="text" 
							v-model.lazy="runningWater" :attr="{maxlength:4}">万元</mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">营业执照时间</span>
							</div>
							<div class="mint-cell-value">
								<span id="businessLicenseTime">请选择营业执照时间</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">企业经营年限</span>
							</div>
							<div class="mint-cell-value">
								<span id="businessYear">请选择企业经营年限</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">所属行业</span>
							</div>
							<div class="mint-cell-value">
								<span id="industry">请选择行业</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">企业经营地址</span>
							</div>
							<div class="mint-cell-value">
								<span id="companyAddress" ref="companyAddresses">请选择企业经营地址</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						
						
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">个人信用状态</span>
						</div>
						<div class="mint-cell-value">
							<span id="creditStatus">请选择个人信用状态</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">征信查询次数</span>
						</div>
						<div class="mint-cell-value">
							<span id="creditQueryCount">请选择征信查询次数</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">信用卡额度</span>
						</div>
						<div class="mint-cell-value">
							<span id="creditLimit">请选择信用卡额度</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">是否有成功借款</span>
						</div>
						<div class="mint-cell-value">
							<span id="loanSuccess">请选择是否有成功借款</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">
								是否有微粒贷
								<a class="checks" @click="checkWld">如何查看微粒贷？</a>
							</span>
						</div>
						<div class="mint-cell-value">
							<span id="isWld">请选择</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					
					<div v-show="isNotWld">
						<mt-field class="borderBottom" label="微粒贷额度" placeholder="请输入微粒贷额度" type="text" 
							v-model.lazy="wldLimit">元</mt-field>
					</div>
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">是否有芝麻信用分
							<a class="checks" @click="checkZhima">如何查看芝麻信用分？</a>
							</span>
						</div>
						<div class="mint-cell-value">
							<span id="isZhima">请选择</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div v-show="isNotZhima">
						<mt-field class="borderBottom" label="芝麻信用分" placeholder="请输入芝麻信用分" type="text" 
							v-model.lazy="zhimaLimit">分</mt-field>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">名下房产</span>
						</div>
						<div class="mint-cell-value">
							<span id="isHouse">请选择房产</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div v-show="isFangchan">
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">房产类型</span>
							</div>
							<div class="mint-cell-value">
								<span id="houseType">请选择房产类型</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">是否有房产证</span>
							</div>
							<div class="mint-cell-value">
								<span id="isHouseValuation">请选择房产证</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="房产估值" placeholder="请输入房产估值" type="text" 
							v-model.lazy="houseValuation">万元</mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">房产位置</span>
							</div>
							<div class="mint-cell-value">
								<span id="houseAddress" ref="houseAddresses">请选择房产位置</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">名下车产</span>
						</div>
						<div class="mint-cell-value">
							<span id="isCar">请选择车产</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div v-show="isChechan">
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">车产类型</span>
							</div>
							<div class="mint-cell-value">
								<span id="carType">请选择车产类型</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="车产估值" placeholder="请输入车产估值" type="text" 
							v-model.lazy="carValuation">万元</mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">车牌归属地</span>
							</div>
							<div class="mint-cell-value">
								<span id="carPlateAddress" ref="carPlateAddresses">请选择车牌归属地</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
					</div>
					
					<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
						<div class="mint-cell-title">
							<span class="mint-cell-text">名下保单</span>
						</div>
						<div class="mint-cell-value">
							<span id="isInsuranceTime">请选择保单</span>
							<strong class="mint-field-other">&nbsp; > </strong>
						</div>
					</div>
					<div v-show="isBaodan">
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">投保时间</span>
							</div>
							<div class="mint-cell-value">
								<span id="insuranceTime">请选择投保时间</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">保单缴费类型</span>
							</div>
							<div class="mint-cell-value">
								<span id="insuranceStatus">请选择缴费类型</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
						<mt-field class="borderBottom" label="保单缴费金额" placeholder="请输入缴费金额" type="text" 
							v-model.lazy="insuranceMoney">元</mt-field>
						<div class="mint-cell-wrapper borderBottom" style="min-height: 48px;">
							<div class="mint-cell-title">
								<span class="mint-cell-text">保险公司</span>
							</div>
							<div class="mint-cell-value">
								<span id="insuranceName">请选择保险公司</span>
								<strong class="mint-field-other">&nbsp; > </strong>
							</div>
						</div>
					</div>
					
					
					<button @click="nextTick2" class="buttonOne">下一步</button>
				</div>
				
				<!--认证信息-->
				<div id="identification" v-show="stepSan">
					<p class="titleStep">认证信息</p>
					<div class="attestation">
						<div class="twoPic">
							<img src="../images/shebao.png" />
							<span>社保</span>
						</div>
						<div class="twoPic">
							<img src="../images/gongjijin.png" />
							<span>公积金</span>
						</div>
					</div>
					
					<button @click="nextTick3" class="buttonOne">保存</button>
				</div>
				
			</div>
			
			<!--查看微粒贷-->
			<div v-show="showWld">
				<div class="return">
					<strong @click="returnToWld"> < </strong>
					<span>如何查看微粒贷</span>
				</div>
				<embed :style="'height:'+embedHeight+'px'" src="http://static.jinkell.com/rescource/weilidaiUse.html"></embed>
			</div>
			<!--查看芝麻信用分-->
			<div v-show="showZhima">
				<div class="return">
					<strong @click="returnToZhima"> < </strong>
					<span>如何查看芝麻信用分</span>
				</div>
				<embed :style="'height:'+embedHeight+'px'" src="http://static.jinkell.com/rescource/zhimaLetter.html"></embed>
			</div>
			
		</div>
	</body>
	<script type="text/javascript" src="../js/rem.js" ></script>
	<script type="text/javascript" src="../js/vue.js" ></script>
	<script type="text/javascript" src="../js/mint2.2.13.js" ></script>
	<script type="text/javascript" src="../js/mobileSelect.js" ></script>
	<script type="text/javascript" src="../js/axios.min.js" ></script>
	<script type="text/javascript">
		
		new Vue({
			el:"#apply",
			data:{
				stepOne:true,
				stepTwo:false,
				stepSan:false,
				isTwo:true,
				isZhiye:false,//上班族或自由职业者
				isFaren:false,//法人
				isShebao:false,//是否有社保公积金
				isNotWld:false,//是否有微粒贷
				isNotZhima:false,//是否有芝麻信用分
				isFangchan:false,//是否有房产
				isChechan:false,//是否有车产
				isBaodan:false,//是否有保单
				showMain:true,//主要内容
				showWld:false,//微粒贷
				showZhima:false,//芝麻信用分
				embedHeight:null,
				loanName:"",//姓名
				idCard:"",//身份证号码
				loadMoney:"",//贷款金额
				loanMonths:"",//贷款期限
				purpose:"",//贷款用途
				city:"",//贷款城市
				loanAreaId:"",
				marriage:"",//婚姻
				education:"",//学历
				liveCity:"",//居住城市
				liveAreaId:"",
				professionType:"",//职业身份
				unitNature:"",//单位性质
				duty:"",//单位职务
				workYears:"",//工作时间
				income:"",//月总收入
				paymentMethod:"",//发薪方式
				socialFund:"",//是否缴纳社保公积金
				socialMonth:"",//本地社保连续缴纳时间
				fundMonth:"",//本地公积金连续缴纳时间
				unitAdress:"",//现单位地址
				unitAreaId:"",//现单位区县ID
				unitType:"",//企业类型
				unitName:"",//企业名称
				runningWater:"",//月经营流水
				businessLicenseTime:"",//营业执照时间
				businessYear:"",//企业经营年限
				industry:"",//所属行业
				companyAddress:"",//企业经营地址
				companyAreaId:"",//企业经营地址区县ID
				creditStatus:"",//个人信用状态
				creditQueryCount:"",//征信查询次数
				creditLimit:"",//信用卡额度
				loanSuccess:"",//是否有成功借款
				isWld:"",//是否有微粒贷
				wldLimit:"",//微粒贷额度
				isZhima:"",//是否有芝麻信用分
				zhimaLimit:"",//芝麻信用分
				isHouse:"",//名下房产
				houseType:"",//房产类型
				isHouseValuation:"",//是否有房产证
				houseValuation:"",//房产赋值
				houseAddress:"",//房产位置
				houseAreaId:"",//房产位置区县id
				isCar:"",//名下车产
				carType:"",//车产类型
				carValuation:"",//车产估值
				carPlateAddress:"",//车牌归属地
				carAreaId:"",//车牌归属地区县id
				isInsuranceTime:"",//名下保单
				insuranceTime:"",//投保时间
				insuranceStatus:"",//保单缴费类型
				insuranceMoney:"",//保单缴费金额
				insuranceName:"",//保险公司
				
			},
			created(){
				
			},
			methods:{
				//填完基本信息点击下一步
				nextTick1(){
					//去掉空格
					this.loadMoney=this.loadMoney.replace(/\s/g,'');
					this.loanName=this.loanName.replace(/\s/g,'');
					//先把非数字的都替换掉，除了数字和.  
				    this.loadMoney = this.loadMoney.replace(/[^\d.]/g,"");  
				    //必须保证第一个为数字而不是.  
				    this.loadMoney = this.loadMoney.replace(/^\./g,"");  
				    //保证只有出现一个.而没有多个.  
				    this.loadMoney = this.loadMoney.replace(/\.{2,}/g,".");  
				    //保证.只出现一次，而不能出现两次以上  
				    this.loadMoney = this.loadMoney.replace(".","$#$").replace(/\./g,"").replace("$#$",".");
				    //保留1位小数 
				    this.loadMoney = this.loadMoney.replace(/^(\-)*(\d+)\.(\d).*$/,'$1$2.$3');
				    
					
					//实名认证
//					axios.get("").then((data) => {
//						
//					});
					//验证非空
					if(this.loadMoney == "" || this.loadMoney<1 || this.loadMoney>50){
						this.$toast("请输入正确的期望金额"); return;
					}else if(this.loanMonths.loanMonths === undefined){
						this.$toast("请选择贷款期限"); return;
					}else if(this.purpose.purpose === undefined){
						this.$toast("请选择贷款用途"); return;
					}else if(this.city.curValue === null){
						this.$toast("请选择贷款城市"); return;
					}else if(this.marriage.marriage === undefined){
						this.$toast("请选择婚姻"); return;
					}else if(this.education.education === undefined){
						this.$toast("请选择学历"); return;
					}else if(this.liveCity.curValue === null){
						console.log(this.liveCity);
						this.$toast("请选择居住城市"); return;
					}
					
					this.stepOne=false;
					this.isTwo=true;
					this.stepTwo=true;
					
				},
				nextTick2(){
					//this.professionType.professionType
					var self=this;
					//去空格
					this.unitName=this.unitName.replace(/\s/g,'');
					this.duty=this.duty.replace(/\s/g,'');
					
					
					if(this.professionType.professionType === undefined){
						this.$toast("请选择职业身份"); return;
					}else if(this.professionType.professionType === "法人"){
						if(this.unitType.unitType === undefined){
							this.$toast("请选择企业类型"); return;
						}else if(this.unitName === ""){
							this.$toast("请输入企业名称"); return;
						}else if(/[^\d]/g.test(this.runningWater) || this.runningWater=="" || this.runningWater<1 || this.runningWater>500){
							this.runningWater="";
							this.$toast("请输入正确的整数1-500的金额"); return;
						}else if(this.businessLicenseTime.businessLicenseTime === undefined){
							this.$toast("请选择营业执照时间"); return;
						}else if(this.businessYear.businessYear === undefined){
							this.$toast("请选择企业经营年限"); return;
						}else if(this.industry.industry === undefined){
							this.$toast("请选择所属行业"); return;
						}else if(this.companyAddress.curValue === null){
							this.$toast("请选择企业经营地址"); return;
						}
						
					}else{ //上班族或自由职业者
						if(this.unitName === ""){
							this.$toast("请输入单位名称"); return;
						}else if(this.unitNature.unitNature === undefined){
							this.$toast("请选择单位性质"); return;
						}else if(this.duty === ""){
							this.$toast("请输入单位职务"); return;
						}else if(this.workYears.workYears === undefined){
							this.$toast("请选择现单位工作时间"); return;
						}else if(/[^\d]/g.test(this.income) || this.income=="" || this.income<2000 || this.income>30000){
							this.income="";
							this.$toast("请输入正确的整数2000-30000的金额");return;
						}else if(this.paymentMethod.paymentMethod === undefined){
							this.$toast("请选择发薪方式"); return;
						}else if(this.socialFund.socialFund === undefined){
							this.$toast("请选择是否缴纳社保公积金"); return;
						}else if(this.socialFund.socialFund === "是"){
							if(this.socialMonth.socialMonth === undefined){
								this.$toast("请选择本地社保连续缴纳时间");return;
							}else if(this.fundMonth.fundMonth === undefined){
								this.$toast("请选择本地公积金连续缴纳时间"); return;
							}
						}else if(this.unitAddress.curValue === null){
							this.$toast("请选择现单位地址"); return;
						}
						
					}
					
					if(this.creditStatus.creditStatus === undefined){
						this.$toast("请选择个人信用状态"); return;
					}else if(this.creditQueryCount.creditQueryCount === undefined){
						this.$toast("请选择征信查询次数"); return;
					}else if(this.creditLimit.creditLimit === undefined){
						this.$toast("请选择信用卡额度"); return;
					}else if(this.loanSuccess.loanSuccess === undefined){
						this.$toast("请选择是否有成功借款"); return;
					}else if(this.isWld.isWld === undefined){
						this.$toast("请选择是否有微粒贷"); return;
					}else if(this.isWld.isWld === "是"){
						if( /[^\d]/g.test(this.wldLimit) || this.wldLimit === "" || this.wldLimit<500 || this.wldLimit>300000){
							this.wldLimit="";
							this.$toast("请输入500-300000整数的微粒贷金额");return;
						}
					}else if(this.isZhima.isZhima === undefined){
						this.$toast("请选择芝麻信用分"); return;
					}else if(this.isZhima.isZhima === "是"){
						if( /[^\d]/g.test(this.zhimaLimit) || this.zhimaLimit === "" || this.zhimaLimit<350 || this.zhimaLimit>950){
							this.zhimaLimit="";
							this.$toast("请输入350-950整数的芝麻信用分");return;
						}
					}
					
					if(this.isHouse.isHouse === undefined){
						this.$toast("请选择房产"); return;
					}else if(this.isHouse.isHouse != "无房产"){
						if(this.houseType.houseType === undefined){
							this.$toast("请选择房产类型"); return;
						}else if(this.isHouseValuation.isHouseValuation === undefined){
							this.$toast("请选择是否有房产证"); return;
						}else if( /[^\d]/g.test(this.houseValuation) || this.houseValuation === "" || this.houseValuation<50 || this.houseValuation>1000){
							this.houseValuation="";
							this.$toast("请输入50-1000整数的估值金额"); return;
						}else if(this.houseAddress.curValue === null){
							this.$toast("请选择房产位置"); return;
						}
					}
					
					if(this.isCar.isCar === undefined){
						this.$toast("请选择车产"); return;
					}else if(this.isCar.isCar != "无车产"){
						if(this.carType.carType === undefined){
							this.$toast("请选择车产类型"); return;
						}else if( /[^\d]/g.test(this.carValuation) || this.carValuation === "" || this.carValuation<3 || this.carValuation>200){
							this.carValuation="";
							this.$toast("请输入3-200整数的金额"); return;
						}else if(this.houseAddress.curValue === null){
							this.$toast("请选择车牌归属地"); return;
						}
					}
					
					if(this.isInsuranceTime.isInsuranceTime === undefined){
						this.$toast("请选择保单"); return;
					}else if(this.isInsuranceTime.isInsuranceTime === "有保单"){
						if(this.insuranceTime.insuranceTime === undefined){
							this.$toast("请选择投保时间"); return;
						}else if(this.insuranceStatus.insuranceStatus === undefined){
							this.$toast("请选择保单缴费类型"); return;
						}else if( /[^\d]/g.test(this.insuranceMoney) || this.insuranceMoney === "" || this.insuranceMoney<100 || this.insuranceMoney>100000){
							this.insuranceMoney="";
							this.$toast("请输入100-100000整数的金额"); return;
						}else if(this.insuranceName.insuranceName === undefined){
							this.$toast("请选择保险公司"); return;
						}
					}
					
					//提交所有填写资料
//					var params={};
//					axios.post("",{
//						params:params
//					}).then(function(data){
//						
//					});
					
					this.stepOne=false;
					this.stepTwo=false;
					this.stepSan=true;
					this.isTwo=true;
				},
				nextTick3(){
					
				},
				//点击查看微粒贷
				checkWld(){
					this.showMain=false;
					this.showWld=true;
				},
				returnToWld(){
					this.showMain=true;
					this.showWld=false;
				},
				checkZhima(){
					this.showMain=false;
					this.showZhima=true;
				},
				returnToZhima(){
					this.showMain=true;
					this.showZhima=false;
				},
				
				
			},
			mounted(){
				//动态定义embed高度
				let h = window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
				this.embedHeight=h-50;
				
				this.loanMonths=new MobileSelect({
	                trigger: "#loanMonths",
	                title: "贷款期限",
	                wheels: [
	                    {data: ["1个月","3个月","6个月","9个月","12个月","18个月"]}
	                ],
	                callback:function(indexArr, data){
//	                	console.log(data);
	                	this.loanMonths=data[0];
	                    
	                }
	            });
	            this.purpose=new MobileSelect({
	                trigger: "#purpose",
	                title: "贷款用途",
	                wheels: [
	                    {data: ["日常消费","结婚","购车","旅游","医疗"]}
	                ],
	                callback:function(indexArr, data){
	                	this.purpose=data[0];
	                }
	            });
	            var self=this;
	            //需要生成全国的省市县对应json
	            axios.get("city3.json").then(function(response){
					self.city=new MobileSelect({
		                trigger: "#city",
		                title: "贷款城市",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.city=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.citys.innerText=data[1].value;
							self.loanAreaId=data[2].id;
//							console.log(self.loanAreaId);
		                }
		            });
				});
				this.marriage=new MobileSelect({
	                trigger: "#marriage",
	                title: "婚姻",
	                wheels: [
	                    {data: ["未婚","已婚","离婚","再婚","丧偶"]}
	                ],
	                callback:function(indexArr, data){
	                	this.marriage=data[0];
	                }
	            });
	            this.education=new MobileSelect({
	                trigger: "#education",
	                title: "学历",
	                wheels: [
	                    {data: ["博士","硕士","本科","高中及以下"]}
	                ],
	                callback:function(indexArr, data){
	                	this.education=data[0];
	                }
	            });
	            axios.get("city3.json").then(function(response){
					self.liveCity=new MobileSelect({
		                trigger: "#liveCity",
		                title: "居住城市",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.liveCity=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.liveCitys.innerText=data[1].value;
							self.liveAreaId=data[2].id;
//							console.log(self.city);
		                }
		            });
				});
				this.professionType=new MobileSelect({
	                trigger: "#professionTypes",
	                title: "职业身份",
	                wheels: [
	                    {data: ["上班族","自由职业者","法人"]}
	                ],
	                callback:function(indexArr, data){
	                	this.professionType=data[0];
	                	if(this.professionType == "上班族" || this.professionType == "自由职业者"){
	                		self.isZhiye=true;
	                		self.isFaren=false;
	                	}else{
	                		self.isFaren=true;
	                		self.isZhiye=false;
	                	}
	                	console.log(this.professionType);
	                }
	            });
	            this.unitNature=new MobileSelect({
	                trigger: "#unitNature",
	                title: "单位性质",
	                wheels: [
	                    {data: ["公务员/事业单位员工","国企单位员工","世界500强企业员工","上市企业员工","外资企业","民营企业"]}
	                ],
	                callback:function(indexArr, data){
	                	this.unitNature=data[0];
	                	console.log(this.unitNature);
	                }
	            });
	            this.workYears=new MobileSelect({
	                trigger: "#workYears",
	                title: "工作时间",
	                wheels: [
	                    {data: ["3个月以下","3个月-6个月","6个月-12个月","1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.workYears=data[0];
	                	console.log(this.workYears);
	                }
	            });
	            this.paymentMethod=new MobileSelect({
	                trigger: "#paymentMethod",
	                title: "发薪方式",
	                wheels: [
	                    {data: ["3个月以下","3个月-6个月","6个月-12个月","1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.paymentMethod=data[0];
	                	console.log(this.paymentMethod);
	                }
	            });
	            this.socialFund=new MobileSelect({
	                trigger: "#socialFund",
	                title: "是否缴纳社保/公积金",
	                wheels: [
	                    {data: ["是","否"]}
	                ],
	                callback:function(indexArr, data){
	                	this.socialFund=data[0];
	                	if(this.socialFund == "是"){
	                		self.isShebao=true;
	                	}else{
	                		self.isShebao=false;
	                	}
	                	console.log(this.socialFund);
	                }
	            });
	            this.socialMonth=new MobileSelect({
	                trigger: "#socialMonth",
	                title: "本地社保连续缴纳时间",
	                wheels: [
	                    {data: ["无社保","3个月以下","3个月-6个月","6个月-12个月","1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.socialMonth=data[0];
	                	console.log(this.socialMonth);
	                }
	            });
	            this.fundMonth=new MobileSelect({
	                trigger: "#fundMonth",
	                title: "本地公积金连续缴纳时间",
	                wheels: [
	                    {data: ["无公积金","3个月以下","3个月-6个月","6个月-12个月","1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.fundMonth=data[0];
	                	console.log(this.fundMonth);
	                }
	            });
	            axios.get("city3.json").then(function(response){
					self.unitAddress=new MobileSelect({
		                trigger: "#unitAddress",
		                title: "现单位地址",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.unitAddress=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.unitAddresses.innerText=data[1].value;
							self.unitAreaId=data[2].id;
							console.log(self.unitAddress);
		                }
		            });
				});
	            
	            this.unitType=new MobileSelect({
	                trigger: "#unitType",
	                title: "企业类型",
	                wheels: [
	                    {data: ["个体工商户","有限责任公司","其他"]}
	                ],
	                callback:function(indexArr, data){
	                	this.unitType=data[0];
	                	console.log(this.unitType);
	                }
	            });
	            this.businessLicenseTime=new MobileSelect({
	                trigger: "#businessLicenseTime",
	                title: "营业执照时间",
	                wheels: [
	                    {data: ["无营业执照","营业执照未满3个月","营业执照已满6个月","营业执照满1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.businessLicenseTime=data[0];
	                	console.log(this.businessLicenseTime);
	                }
	            });
	            this.businessYear=new MobileSelect({
	                trigger: "#businessYear",
	                title: "企业经营年限",
	                wheels: [
	                    {data: ["3个月以下","3个月-6个月","6个月-12个月","1年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.businessYear=data[0];
	                	console.log(this.businessYear);
	                }
	            });
	            this.industry=new MobileSelect({
	                trigger: "#industry",
	                title: "所属行业",
	                wheels: [
	                    {data: ["农、林、牧、渔业", "采矿业", "制造业", "电力、热力、燃气及水生产和供应业", "建筑业", "批发和零售业", "交通运输", "仓储和邮政业", "住宿和餐饮业", 
	                    "信息传输", "软件和信息技术服务业", "金融业", "房地产业", "租赁和商务服务业", "科学研究和技术服务业", "水利",
	                    "环境和公共设施管理业", "居民服务", "修理和其他服务业", "教育", "卫生和社会工作", "文化", "体育和娱乐业", "公共管理", "社会保障和社会组织", "国际组织"]}
	                ],
	                callback:function(indexArr, data){
	                	this.industry=data[0];
	                	console.log(this.industry);
	                }
	            });
	            axios.get("city3.json").then(function(response){
					self.companyAddress=new MobileSelect({
		                trigger: "#companyAddress",
		                title: "企业经营地址",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.companyAddress=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.companyAddresses.innerText=data[1].value;
							self.companyAreaId=data[2].id;
							console.log(self.companyAddress);
		                }
		            });
				});
				this.creditStatus=new MobileSelect({
	                trigger: "#creditStatus",
	                title: "个人信用状态",
	                wheels: [
	                    {data: ["无信用卡或贷款","信用良好，无逾期","一年内逾期少于三次且少于90天","一年内逾期超过三次或超过90天"]}
	                ],
	                callback:function(indexArr, data){
	                	this.creditStatus=data[0];
	                	console.log(this.creditStatus);
	                }
	            });
	            this.creditQueryCount=new MobileSelect({
	                trigger: "#creditQueryCount",
	                title: "征信查询次数",
	                wheels: [
	                    {data: ["不清楚","0次","1-3次","4-6次","6次及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.creditQueryCount=data[0];
	                	console.log(this.creditQueryCount);
	                }
	            });
	            this.creditLimit=new MobileSelect({
	                trigger: "#creditLimit",
	                title: "信用卡额度",
	                wheels: [
	                    {data: ["无信用卡","5千以内","5千-2万元","2万-5万元","5万元以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.creditLimit=data[0];
	                	console.log(this.creditLimit);
	                }
	            });
	            this.loanSuccess=new MobileSelect({
	                trigger: "#loanSuccess",
	                title: "是否有成功贷款",
	                wheels: [
	                    {data: ["是","否"]}
	                ],
	                callback:function(indexArr, data){
	                	this.loanSuccess=data[0];
	                	console.log(this.loanSuccess);
	                }
	            });
            	this.isWld=new MobileSelect({
	                trigger: "#isWld",
	                title: "是否有微粒贷",
	                wheels: [
	                    {data: ["是","否"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isWld=data[0];
	                	if(this.isWld == "是"){
	                		self.isNotWld=true;
	                	}else{
	                		self.isNotWld=false;
	                	}
	                	console.log(this.isWld);
	                }
	            });
	            this.isZhima=new MobileSelect({
	                trigger: "#isZhima",
	                title: "是否有芝麻信用分",
	                wheels: [
	                    {data: ["是","否"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isZhima=data[0];
	                	if(this.isZhima == "是"){
	                		self.isNotZhima=true;
	                	}else{
	                		self.isNotZhima=false;
	                	}
	                	console.log(this.isZhima);
	                }
	            });
	            this.isHouse=new MobileSelect({
	                trigger: "#isHouse",
	                title: "名下房产",
	                wheels: [
	                    {data: ["无房产","有房产不接受抵押","有房产接受抵押","有房产已抵押"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isHouse=data[0];
	                	if(this.isHouse != "无房产"){
	                		self.isFangchan=true;
	                	}else{
	                		self.isFangchan=false;
	                	}
	                	console.log(this.isHouse);
	                }
	            });
	            this.houseType=new MobileSelect({
	                trigger: "#houseType",
	                title: "房产类型",
	                wheels: [
	                    {data: ["商品房","商住两用房","商铺","别墅","拆迁房","自建房"]}
	                ],
	                callback:function(indexArr, data){
	                	this.houseType=data[0];
	                	console.log(this.houseType);
	                }
	            });
	            this.isHouseValuation=new MobileSelect({
	                trigger: "#isHouseValuation",
	                title: "是否有房产证",
	                wheels: [
	                    {data: ["无房产证","有房产证"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isHouseValuation=data[0];
	                	console.log(this.isHouseValuation);
	                }
	            });
	            axios.get("city3.json").then(function(response){
					self.houseAddress=new MobileSelect({
		                trigger: "#houseAddress",
		                title: "房产位置",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.houseAddress=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.houseAddresses.innerText=data[1].value;
							self.houseAreaId=data[2].id;
							console.log(self.houseAddress);
		                }
		            });
				});
	           	this.isCar=new MobileSelect({
	                trigger: "#isCar",
	                title: "名下车产",
	                wheels: [
	                    {data: ["无车产","有车产不接受抵押","有车产接受抵押","有车产已抵押"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isCar=data[0];
	                	if(this.isCar != "无车产"){
	                		self.isChechan=true;
	                	}else{
	                		self.isChechan=false;
	                	}
	                	console.log(this.isCar);
	                }
	            });
	            this.carType=new MobileSelect({
	                trigger: "#carType",
	                title: "车产类型",
	                wheels: [
	                    {data: ["全款车","按揭车"]}
	                ],
	                callback:function(indexArr, data){
	                	this.carType=data[0];
	                	console.log(this.carType);
	                }
	            });
	            axios.get("city2.json").then(function(response){
					self.carPlateAddress=new MobileSelect({
		                trigger: "#carPlateAddress",
		                title: "车牌归属地",
		                wheels: [
		                    {data: response.data}
		                ],
		                callback:function(indexArr, data){
		                	self.carPlateAddress=data[0].value+data[1].value+data[2].value;
		                	//显示二级城市
							self.$refs.carPlateAddresses.innerText=data[1].value;
							self.carAreaId=data[2].id;
							console.log(self.carPlateAddress);
		                }
		            });
				});
				this.isInsuranceTime=new MobileSelect({
	                trigger: "#isInsuranceTime",
	                title: "名下保单",
	                wheels: [
	                    {data: ["无保单","有保单"]}
	                ],
	                callback:function(indexArr, data){
	                	this.isInsuranceTime=data[0];
	                	if(this.isInsuranceTime === "有保单"){
	                		self.isBaodan=true;
	                	}else{
	                		self.isBaodan=false;
	                	}
	                	console.log(this.isInsuranceTime);
	                }
	            });
	            this.insuranceTime=new MobileSelect({
	                trigger: "#insuranceTime",
	                title: "投保时间",
	                wheels: [
	                    {data: ["投保不满1年","投保满1年","投保满2年及以上"]}
	                ],
	                callback:function(indexArr, data){
	                	this.insuranceTime=data[0];
	                	console.log(this.insuranceTime);
	                }
	            });
	            this.insuranceStatus=new MobileSelect({
	                trigger: "#insuranceStatus",
	                title: "保单缴费类型",
	                wheels: [
	                    {data: ["月缴","季缴","年缴"]}
	                ],
	                callback:function(indexArr, data){
	                	this.insuranceStatus=data[0];
	                	console.log(this.insuranceStatus);
	                }
	            });
	            this.insuranceName=new MobileSelect({
	                trigger: "#insuranceName",
	                title: "保险公司",
	                wheels: [
	                    {data: ["平安保险", "中国人寿", "新华人寿", "泰康人寿", "东吴人寿","友邦保险","太平洋保险","阳光保险","招商信诺","其他保险公司"]}
	                ],
	                callback:function(indexArr, data){
	                	this.insuranceName=data[0];
	                	console.log(this.insuranceName);
	                }
	            });
	            
	            
	            
			},
		
		
		})
	</script>
	
</html>
